package com.woniuxy.woniuticket;

import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.servlet.ServletComponentScan;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
import org.springframework.context.annotation.Bean;
import org.springframework.transaction.annotation.EnableTransactionManagement;
import org.springframework.web.socket.server.standard.ServerEndpointExporter;

@SpringBootApplication
@EnableTransactionManagement
@ServletComponentScan
//@MapperScan(value={"com.woniuxy.woniuticket.searchmodule.repository","com.woniuxy.woniuticket.movieinfomodule.dao","com.woniuxy.woniuticket.ordermodule.dao","com.woniuxy.woniuticket.moviemodule.dao","com.woniuxy.woniuticket.*.dao"})
public class WoniuticketApplication extends SpringBootServletInitializer {

    public static void main(String[] args) {
        /*解决ES冲突*/
        System.setProperty("es.set.netty.runtime.available.processors", "false");
        SpringApplication.run(WoniuticketApplication.class, args);
        System.out.println("启动完成");
    }



    @Override
    protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
        return builder.sources(WoniuticketApplication.class);
    }

}
